package com.hospital.service.util;

import com.hospital.entity.Doctor;
import com.hospital.enumeration.BusinessExceptionEnum;
import com.hospital.exception.BusinessException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class DoctorCheckUtil {
    public void checkDoctor(Doctor doctor) {
        if (doctor == null) {
            throw new BusinessException(BusinessExceptionEnum.DOCTOR_NOT_EXIST);
        }
    }
}
